/**
 * 
 */
package com.nextive.interview.exception;

/**
 * This exception is intended to be used when a specific service has not been registered.
 * @author Cesar Roman
 *
 */
public class ServiceNotRegisteredException extends RuntimeException {
	
	/**
	 * Service involved in the exception.
	 */
	private Class service;
	
	/**
	 * Default constructor.
	 * @param serviceIn
	 */
	public ServiceNotRegisteredException(Class serviceIn) {
		
		service = serviceIn;
	
	}

	/**
	 * It returns the exception message.
	 * @return
	 */
	@Override
	public String getMessage() {
		
		return "The following service can not be registered : " + service;
		
	}
	
}